package com.hxzy.tms.service;

import java.util.Date;
import java.util.List;

import com.hxzy.tms.entity.Task;
import com.hxzy.tms.entity.User;
import com.hxzy.tms.entity.UserTask;

public interface TaskService {
	
	ServiceResult<List<Task>> read(long id);

	ServiceResult<List<UserTask>> commitList(long teamId,long taskId);
    ServiceResult<Task> update(Long id, Long projectId, Long teamId, String title, String desc,
			String attachmentUrl, Date gmtBegin, Date gmtEnd);
    //创建任务
    ServiceResult<Task> create(Long projectId, Long teamId, String title, String desc, String attachmentUrl,Date gmtBegin, Date gmtEnd);
    
    ServiceResult<Task> saveOrUpdate(Long id,Long projectId, Long teamId, String title, String desc, String attachmentUrl,Date gmtBegin, Date gmtEnd);
 
    //提交任务
    ServiceResult<UserTask> update(Long taskId,String attachmentUrl);
    
    ServiceResult<Task> delete(Task task);
    
    //用户的任务列表
    ServiceResult<List<UserTask>> taskList(Long userId);
    
    ServiceResult<List<UserTask>> userTasks(long taskId) ;
}
